import Vue from 'vue'
import axios from "axios"

axios.defaults.baseURL = 'https://m.maizuo.com'
// 添加请求拦截器
axios.interceptors.request.use(function (config) {

  config.headers = {
    "X-Client-Info":
      '{"a":"3000","ch":"1002","v":"5.0.4","e":"1598087896889693885431809","bc":"110100"}',
    "X-Host": "mall.film-ticket.film.list",
  }

  // 在发送请求之前做些什么
  return config;
}, function (error) {
  // 对请求错误做些什么
  return Promise.reject(error);
});

// function regAxios(){
//   Vue.prototype.$axios=axios
// }

//导出 
export default axios